<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <meta http-equiv="X-UA-Compatible" content="ie=edge" />
    <script src="./jquery.js"></script>
    <title>Document</title>
  </head>

  <body>
    <div></div>
    <script>
      var params = location.search.substr(4);
      console.log(params);

      var fun = function () {
        $.post("tab2.php", { id: params }, function (res) {
            var data1 = JSON.parse(res);
          console.log(data1);
          document.querySelector("div ").innerHTML = data1[0].content;
        });
      };
      fun();
    </script>
  </body>
</html>
